/*
 * StudentPhoneDb.h
 *
 *  Created on: 24 Apr 2010
 *      Author: User
 */

#ifndef STUDENTPHONEDB_H_
#define STUDENTPHONEDB_H_
#include "OdbcConnectionSingleton.h"
#include "IStudentPhoneDb.h"
#include <string>

using namespace std;

class StudentPhoneDb:public IStudentPhoneDb {
public:
	
	StudentPhoneDb(const string *dbName, const string *user, const string *passwd);
	virtual ~StudentPhoneDb();
	/**
	 * Insert a phoneNumber
	 * @param phoneNumber, the value phone
	 * @return boolean
	 */
	virtual bool savePhone(const string *phoneNumber) const;
	/**
	 * Set/update phone category by phoneNumber
	 * @param phoneNumber, the value of phone
	 * @param category, the value of category e.g. Moblie,home
	 * @return boolean
	 */
	virtual bool saveCategory(const string *phoneNumber,const string *category) const;
	/**
	 * Set/update the fk Students_aem by phone number
	 * @param phoneNumber, the value of phone
	 * @param aem, the value of aem
	 * @return
	 */
	virtual bool saveStudentAem(const string *phoneNumber,const string *aem) const;
	virtual string *getPhone(const string *aem)=0;
	virtual string *getCategory(const string *aem)=0;

};

#endif /* STUDENTPHONEDB_H_ */
